﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" AutoEventWireup="true"
    CodeBehind="Conversation.aspx.cs" Inherits="Yonkly.Views.Message.Conversation" %>

<%@ Import Namespace="Yonkly.Models" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContentPlaceHolder" runat="server">
<h2>Conversation</h2>
    <% Html.RenderPartial("~/views/message/reply.ascx");%>
    <% Html.RenderPartial("~/views/message/messagechildren.ascx");%>
    <div class="pager">
        <%
            if (((ConversationViewData)ViewData.Model).Children.IsPreviousPage)
            {%>
        <a href='<%=Url.Action("Conversation", "Message",
                                         new RouteValueDictionary(new {Page = ((ConversationViewData)ViewData.Model).Children.PageIndex - 1}))%>'>
            Prev</a>
        <%
            }%>
        <%
            if (((ConversationViewData)ViewData.Model).Children.IsNextPage)
            {%>
        <a href='<%=Url.Action("Conversation", "Message",
                                         new RouteValueDictionary(new {Page = ((ConversationViewData)ViewData.Model).Children.PageIndex + 1}))%>'>
            Next</a>
        <%
            }%>
    </div>
</asp:Content>
